import request from '@/utils/request'
import { Message } from 'element-ui'
/**
 * 获取列表数据
 * @param {*} method 请求方式
 * @param {*} url 请求地址
 * @param {*} data 查找功能的参数
 * @returns 
 */
export const R_tableData = async function({ method, url, data }) {
    let result = await request({
        method: method,
        url: url,
        data: data
    })
    return result
}

/**
 * 新添加一个用户
 * @param {*} param0 
 */
export const R_add = async function({ method, url, data }) {
    let result = await request({
        method: method,
        url: url,
        data: data
    })
    return result
}

/**
 * 修改用户信息
 * @param {*} param0 
 */
export const R_update = async function({ method, url, data }) {
    let result = await request({
        method: method,
        url: url,
        data: data
    })
    return result
}


/**
 * 删除用户
 * @param {*} param0 
 */
export const R_remove = async function({ method, url, data }) {
    let result = await request({
        method: method,
        url: url,
        data: data
    })
    return result
}